package easy.core.util;
import easy.entities.BaseEntity;
import java.util.regex.*;
/**
 *
 * @author Julio
 */
public class ValidaURL extends BaseEntity{
    private static final long serialVersionUID = 4221749590865725555L;

    public static boolean testaURL(String x){
        Pattern p = Pattern.compile("/http://[A-Za-z0-9.-]{3,}.[A-Za-z]{3}/");
        Matcher m = p.matcher(x);
        if (!m.find()){
            System.err.println("URL valida");
            return false;
        }else{
            System.err.println("URL Invalida");
           return true;
        }
        }
    public static void main (String [] args){
        testaURL("");
    }

}